package vn.fsoft.gst.domain;

import java.util.List;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.Table;

import org.hibernate.annotations.LazyCollection;
import org.hibernate.annotations.LazyCollectionOption;

/**
 *
 * @author MinhNT
 *
 */
@Entity
@Table(name = "directorate")
public class Directorate {
    /**
    *
    * @category directorateID
    *
    */
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "DirectorateID")
    private int directorateID;
    /**
    *
    * @category isActive
    *
    */
    @Column(name = "IsActive")
    private boolean isActive;
    /**
    *
    * @category directorate Name
    *
    */
    @Column(name = "DirectorateName")
    private String directorateName;
    /**
    *
    * @category description Short
    *
    */
    @Column(name = "DescriptionShort")
    private String descriptionShort;
    /**
    *
    * @category description Full
    *
    */
    @Column(name = "DescriptionFull")
    private String descriptionFull;
    /**
    *
    * @category address Line1
    *
    */
    @Column(name = "AddressLine1")
    private String addressLine1;
    /**
    *
    * @category address Line2
    *
    */
    @Column(name = "AddressLine2")
    private String addressLine2;
    /**
    *
    * @category address Line3
    *
    */
    @Column(name = "AddressLine3")
    private String addressLine3;
    /**
    *
    * @category sic code
    *
    */
    @Column(name = "SICCode", columnDefinition = "char(5)")
    private String sicCode;
    /**
    *
    * @category phone
    *
    */
    @Column(name = "PhoneNumber", columnDefinition = "char(10)")
    private String phoneNumber;
    /**
    *
    * @category fax
    *
    */
    @Column(name = "Fax", columnDefinition = "char(10)")
    private String fax;
    /**
    *
    * @category email
    *
    */
    @Column(name = "Email")
    private String email;
    /**
    *
    * @category web Address
    *
    */
    @Column(name = "WebAddress")
    private String webAddress;
    /**
    *
    * @category charity Number
    *
    */
    @Column(name = "CharityNumber")
    private String charityNumber;
    /**
    *
    * @category company Number
    *
    */
    @Column(name = "CompanyNumber")
    private String companyNumber;
    /**
    *
    * @category organisation
    * Relation many to one with Organisation
    */
    @ManyToOne
    @JoinColumn(name = "OrgID")
    private Organisation organisation;
    /**
    *
    * @category listDepartment
    * Relation one to many with Department
    */
    @OneToMany(mappedBy = "directorate")
    @LazyCollection(LazyCollectionOption.FALSE)
    private List<Department> listDepartment;
    /**
    *
    * @category address
    * Relation many to one with Address
    */
    @ManyToOne
    @JoinColumn(name = "AddressID")
    private Address address;
    /**
    *
    * @category contact
    * Relation mant to one with Contact
    */
    @ManyToOne
    @JoinColumn(name = "ContactID")
    private Contact contact;
    /**
     *
     *@category get DirectorateID from directorate
     * @return
     * directorateID
     */
    public int getDirectorateID() {
         return directorateID;
    }
    /**
     *
     *@category set DirectorateID for directorate
     * @param directorateID
     * directorateID of directorate
     */
    public void setDirectorateID(int directorateID) {
        this.directorateID = directorateID;
    }
    /**
     *
     *@category get isActive from directorate
     * @return
     * output true or false
     */
    public boolean getIsActive() {
        return isActive;
    }
    /**
     *
     * @category set status for directorate
     * @param isActive
     * isActive of directorate
     */
    public void setIsActive(boolean isActive) {
         this.isActive = isActive;
    }
    /**
     *
     * @return
     */
    public String getDirectorateName() {
        return directorateName;
    }
    /**
     *
     * @param directorateName
     */
    public void setDirectorateName(String directorateName) {
        this.directorateName = directorateName;
    }
    /**
     *
     * @return
     */
    public String getDescriptionShort() {
        return descriptionShort;
    }
    /**
     *
     * @param descriptionShort
     */
    public void setDescriptionShort(String descriptionShort) {
        this.descriptionShort = descriptionShort;
    }
    /**
     *
     * @return
     */
    public String getDescriptionFull() {
        return descriptionFull;
    }
    /**
     *
     * @param descriptionFull
     */
    public void setDescriptionFull(String descriptionFull) {
        this.descriptionFull = descriptionFull;
    }
    /**
     *
     * @return
     */
    public String getAddressLine1() {
        return addressLine1;
    }
    /**
     *
     * @param addressLine1
     */
    public void setAddressLine1(String addressLine1) {
        this.addressLine1 = addressLine1;
    }
    /**
     *
     * @return
     */
    public String getAddressLine2() {
        return addressLine2;
    }
    /**
     *
     * @param addressLine2
     */
    public void setAddressLine2(String addressLine2) {
        this.addressLine2 = addressLine2;
    }
    /**
     *
     * @return
     */
    public String getAddressLine3() {
        return addressLine3;
    }
    /**
     *
     * @param addressLine3
     */
    public void setAddressLine3(String addressLine3) {
        this.addressLine3 = addressLine3;
    }
    /**
     *
     * @return
     */
    public String getSicCode() {
        return sicCode;
    }
    /**
     *
     * @param sicCode
     */
    public void setSicCode(String sicCode) {
        this.sicCode = sicCode;
    }
    /**
     *
     * @return
     */
    public String getPhoneNumber() {
        return phoneNumber;
    }
    /**
     *
     * @param phoneNumber
     */
    public void setPhoneNumber(String phoneNumber) {
        this.phoneNumber = phoneNumber;
    }
    /**
     *
     * @return
     */
    public String getFax() {
        return fax;
    }
    /**
     *
     * @param fax
     */
    public void setFax(String fax) {
        this.fax = fax;
    }
    /**
     *
     * @return
     */
    public String getEmail() {
        return email;
    }
    /**
     *
     * @param email
     */
    public void setEmail(String email) {
        this.email = email;
    }
    /**
     * 
     * @return
     */
    public String getWebAddress() {
        return webAddress;
    }
    /**
     *
     * @param webAddress
     */
    public void setWebAddress(String webAddress) {
        this.webAddress = webAddress;
    }
    /**
     *
     * @return
     */
    public String getCharityNumber() {
        return charityNumber;
    }
    /**
     *
     * @param charityNumber
     */
    public void setCharityNumber(String charityNumber) {
        this.charityNumber = charityNumber;
    }
    /**
     *
     * @return
     */
    public String getCompanyNumber() {
        return companyNumber;
    }
    /**
     *
     * @param companyNumber
     */
    public void setCompanyNumber(String companyNumber) {
        this.companyNumber = companyNumber;
    }
    /**
     *
     * @return
     */
    public Organisation getOrganisation() {
        return organisation;
    }
    /**
     *
     * @param organisation
     */
	public void setOrganisation(Organisation organisation) {
	    this.organisation = organisation;
    }
    /**
     *
     * @return
     */
    public Address getAddress() {
        return address;
    }
    /**
     *
     * @param address
     */
    public void setAddress(Address address) {
        this.address = address;
    }
    /**
     *
     * @return
     */
    public Contact getContact() {
        return contact;
    }
    /**
     *
     * @param contact
     */
    public void setContact(Contact contact) {
        this.contact = contact;
    }
}
